-- GENERATED SPELL FOR [Bloodmaul Shaman] --


function spell0_19992(pUnit, Event) --@Bloodmaul Buzz,Self--
pUnit:FullCastSpellOnTarget(34932,pUnit)
pUnit:RegisterEvent('Sorts_19992', 20321, 1)
end

function spell1_19992(pUnit, Event) --@Lightning Shield,n/a--
pUnit:FullCastSpellOnTarget(12550,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_19992', 0, 1)
end

function spell2_19992(pUnit, Event) --@Scorching Totem,Self--
if charge_disp ~= 'na' then
pUnit:FullCastSpellOnTarget(15038,pUnit)
local charge_disp = 'na'
end
pUnit:RegisterEvent('Sorts_19992', 1, 1)
end

function spell3_19992(pUnit, Event) --@Superior Healing Ward,Self--
pUnit:FullCastSpellOnTarget(15869,pUnit)
pUnit:RegisterEvent('Sorts_19992', 32000, 1)
end

function Sorts_19992(pUnit, Event)
local choix_sorts_19992 = math.random(0, 3)
if choix_sorts_19992 == 0 then
pUnit:RegisterEvent('spell0_19992', 1, 1)
end
if choix_sorts_19992 == 1 then
pUnit:RegisterEvent('spell1_19992', 1, 1)
end
if choix_sorts_19992 == 2 then
pUnit:RegisterEvent('spell2_19992', 1, 1)
end
if choix_sorts_19992 == 3 then
pUnit:RegisterEvent('spell3_19992', 1, 1)
end
end

function mob19992_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_19992', math.random(1500, 3000), 1)
end

function mob19992_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob19992_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob19992_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(19992, 1, 'mob19992_Action')
RegisterUnitEvent(19992, 2, 'mob19992_Leave')
RegisterUnitEvent(19992, 3, 'mob19992_Kill')
RegisterUnitEvent(19992, 4, 'mob19992_Die')
